﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace 加密测试
{
    class Program
    {
        static void Main(string[] args)
        {
           	String pwd = "vj4td8wx";
           // pwd = "";
		    String key = "62523645";
            //key = "";
            string desResult= Encrypt.EncryptDES(pwd, key);

            string decrypt= Encrypt.DecryptDES(desResult, key);
            Console.WriteLine(decrypt);

           // int left=22;
           // int right=2;
           // cs += String.Concat((char)RM(left, 24),
           //           (char)(RM(left, 16) & 0xff),
           //           (char)(RM(left, 8) & 0xff),
           //           (char)(left & 0xff),
           //           (char)RM(right, 24),
           //           (char)(RM(right, 16) & 0xff),
           //           (char)(RM(right, 8) & 0xff),
           //           (char)(right & 0xff)); 

           // Console.WriteLine(desResult);

           //int i= RM(-int.MaxValue, 8);
        }

        public static int RM(int a,int bit)
        { 
            //unchecked
            {
                uint b = (uint)a;
                b = b >> bit;
                return (int)b;
            }
        }
    }
}
